﻿// STATS MODULE
//      Luca Puccini
//      Marco Cornolti
//      Michele Sottile
//      Matteo Parchi

// GENERAL STAS OBJECT

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Stats.Objects
{

    /// <summary>
    /// Represents the object returned when general statistics are requested
    /// </summary>
    public class GeneralStats
    {
        /// <summary>
        /// Total of money saved (Euro) by all users of TriploA
        ///</summary>
        public double TotalMoneySaved { get; set; }

        /// <summary>
        /// Total of fuel saved (Liter) by all users of TriploA
        ///</summary>
        public double TotalFuelSaved { get; set; }

        /// <summary>
        /// Total of pollution saved by all users of TriploA
        ///</summary>
        public double TotalPollutionSaved { get; set; }

        /// <summary>
        /// Total of km done by all users of TriploA
        ///</summary>
        public double TotalKm { get; set; }

        /// <summary>
        /// Total of passengers carried by all users of TriploA
        ///</summary>
        public int TotalPassengersCarried { get; set; }

        /// <summary>
        /// Max number of passengers carried by all users of TriploA on a single trip
        ///</summary>
        public int MaxPassengerCarried { get; set; }

        /// <summary>
        /// Number of trips proposed by all users of TriploA
        ///</summary>
        public int ProposedTripsNumber { get; set; }

        /// <summary>
        /// Number of trips completed by all users of TriploA
        ///</summary>
        public int CompletedTripsNumber { get; set; }

        /// <summary>
        /// Total Km divided by total number of trips
        ///</summary>
        public double AverageTripsKm { get; set; }

        /// <summary>
        /// Total of passengers carried on the way by all users of TriploA
        ///</summary>
        public int PassengersCarriedOnWayNumber { get; set; }

        /// <summary>
        /// Total number of registered users
        ///</summary>
        public int RegisteredUsers { get; set; }

        /// <summary>
        /// Number of missed appointment by drivers
        ///</summary>
        public int MissedAppointmentsByDrivers { get; set; }

        /// <summary>
        /// Number of missed appointment by passengers
        ///</summary>
        public int MissedAppointmentsByPassengers { get; set; }

        /// <summary>
        /// Number of days referred by the DailyStatsTable
        ///</summary>
        public int NumberDaysStatsReferred { get; set; }      
        
        /// <summary>
        /// Constructor for the GeneralStas object with general statistics about trips, users...
        /// </summary>
        /// <param name="totalMoneySaved">Total of money saved (Euro) by all user of TriploA</param>    
        /// <param name="fuelSaved">Total of fuel saved (Liter) by all user of TriploA</param>
        /// <param name="totalPollutionSaved">Total of pollution saved by all user of TriploA</param>        
        /// <param name="kmDone">Total of km done by all user of TriploA</param>
        /// <param name="totalPsnCarried">Total of passengers carried by all user of TriploA</param>
        /// <param name="maxPSNcarried">Max number of passengers carried by all user of TriploA on a single trip</param>
        /// <param name="tripsProposed">Number of trips proposed by all user of TriploA</param>
        /// <param name="tripsCompleted">Number of trips handshaked by all user of TriploA</param>
        /// <param name="averageKm">Total Km divided by total number of trips</param>
        /// <param name="totalPsnCarriedOnWay">Total of passengers carried on the way by all user of TriploA</param>
        /// <param name="registeredUsers">Total number of registered users</param>
        /// <param name="missedTripsByDr">Number of missed appointment by drivers</param>
        /// <param name="missedTripsByPsg">Number of missed appointment by passengers</param>
        /// <param name="nDays">Number of days referred by the DailyStatsTable</param>
        public GeneralStats (double totalMoneySaved, double fuelSaved, double totalPollutionSaved, double kmDone,int totalPsnCarried,int maxPSNcarried,
            int tripsProposed,int tripsCompleted,double averageKm, int totalPsnCarriedOnWay, int registeredUsers, int missedTripsByDr, int missedTripsByPsg,int nDays)
        
        {
            TotalMoneySaved = totalMoneySaved;
            TotalFuelSaved = fuelSaved;
            TotalPollutionSaved = totalPollutionSaved;
            TotalKm = kmDone;
            TotalPassengersCarried = totalPsnCarried;
            MaxPassengerCarried = maxPSNcarried;
            ProposedTripsNumber = tripsProposed;
            CompletedTripsNumber = tripsCompleted;
            AverageTripsKm = averageKm;
            PassengersCarriedOnWayNumber = totalPsnCarriedOnWay;
            RegisteredUsers = registeredUsers;
            MissedAppointmentsByDrivers = missedTripsByDr;
            MissedAppointmentsByPassengers = missedTripsByPsg;

            NumberDaysStatsReferred = nDays;
            
        }

        /////<summary> 
        /////Gets total of money saved (EURO) by all users of TriploA
        /////</summary>
        ///// <returns>double</returns>
        //public double TotalMoneySaved
        //{
        //    get { return total_money_saved; }
        //}

        /////<summary> 
        /////Gets total of fuel saved (LITER) by all users of TriploA
        /////</summary>
        ///// <returns>double</returns>
        //public double TotalFuelSaved
        //{
        //    get { return total_fuel_saved; }
        //}

        /////<summary> 
        /////Gets total of pollution saved by all users of TriploA
        /////</summary>
        ///// <returns>double</returns>
        //public double TotalPollutionSaved
        //{
        //    get { return total_pollution_saved; }
        //}

        /////<summary> 
        /////Gets total of km done by all users of TriploA
        /////</summary> 
        ///// <returns>double</returns>
        //public double TotalKm
        //{
        //    get {return total_km_done;}
        //}

        /////<summary> 
        /////Gets total number of passenger carried by all users of TriploA
        /////</summary>
        ///// <returns>int</returns>
        //public int TotalPassengersCarried
        //{
        //    get { return total_passengers_carried; }
        //}
        /////<summary> 
        /////Gets max number of passenger carried by all users of TriploA
        /////</summary>
        ///// <returns>int</returns>
        //public int MaxPassengersCarried
        //{
        //    get { return max_passenger_carried; }
        //}
        
        /////<summary> 
        /////Gets number of proposed trips by all users of TriploA
        /////</summary>
        ///// <returns>int</returns>
        //public int ProposedTripsNumber
        //{
        //    get {return trips_proposed_number;}
        //}


        /////<summary> 
        /////Gets number of entire TriploA completed trips  
        /////</summary>
        ///// <returns>int</returns>
        //public int CompletedTripsNumber
        //{
        //    get {return trips_completed_number;}
        //}

        /////<summary> 
        /////Gets average of the km of the entire TriploA trips  
        /////</summary>
        ///// <returns>double</returns>
        //public double AverageTripsKm
        //{
        //    get { return average_trips_km; }
        //}

        /////<summary> 
        /////Gets total number of passenger carried oin the way by all users of TriploA
        /////</summmary>
        ///// <returns>int</returns>
        //public int PassengersCarriedOnWayNumber
        //{
        //    get { return total_passengers_carried_onWay; }
        //}

        /////<summary> 
        /////Gets total number of registered users of TriploA
        /////</summmary>
        ///// <returns>int</returns>
        //public int RegisteredUsers
        //{
        //    get { return registered_users; }
        //}

        /////<summary> 
        /////Gets number of entire TriploA missed trips by Drivers
        /////</summary>
        ///// <returns>int</returns>
        //public int MissedAppointmentsByDrivers
        //{
        //    get {return missedAppointment_byDr;}
        //}

        /////<summary> 
        /////Gets number of entire TriploA missed trips by Passengers
        /////</summary>
        ///// <returns>int</returns>
        //public int MissedAppointmentsByPassengers
        //{
        //    get { return missedAppointment_byPsg; }
        //}

        /////<summary> 
        /////Gets the number of days about stats are referred
        /////</summary>
        ///// <returns>int</returns>
        //public int NumberDaysStatsReferred
        //{
        //    get { return number_Days_statsReferred; }
        //}
    }
}
